<?php
// +----------------------------------------------------------------------
// | ThinkPHP [ WE CAN DO IT JUST THINK ]
// +----------------------------------------------------------------------
// | Copyright (c) 2006~2018 http://thinkphp.cn All rights reserved.
// +----------------------------------------------------------------------
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
// +----------------------------------------------------------------------
// | Author: liu21st <liu21st@gmail.com>
// +----------------------------------------------------------------------
use think\facade\Route;

Route::rule('/','index/index');


Route::rule('chisha','index/chisha');
Route::rule('test','index/test');
Route::rule('login','user/login')->prefix('admin/');



Route::rule('register','user/register')->prefix('admin/');

Route::rule('logout','user/logout')->prefix('admin/');

Route::rule('user/:id','user/userinfo')->prefix('admin/');
Route::rule('upload_img','admin/index/upload_img');
Route::rule('admin/','admin/index/index');
Route::group('admin',function(){
	Route::rule('/','index/index');
	Route::group('user/',function(){
		Route::rule('/','user/index');
		Route::rule('edit/:id','user/edit');
		Route::rule('delete/:id','user/delete');
	});
	Route::group('role/',function(){
		Route::rule('/','role/index');
		Route::rule('addRole','role/addRole');
		Route::rule('edit/:id','role/edit');
		Route::rule('getInfo','role/getInfo');
	});
	Route::group('good/',function(){
		Route::rule('/','good/index');
		Route::rule('add','good/addGood');
		Route::rule('getInfo','good/getInfo');
		Route::rule('edit/:id','good/edit');
		Route::rule('del/:id','good/del');
	});
	Route::group('category/',function(){
		Route::rule('/','category/index');
		Route::rule('addCateGory','category/addCateGory');
		Route::rule('getInfo','category/getInfo');
		Route::rule('edit/:id','category/edit');
		Route::rule('del/:id','category/del');
	});
})->prefix('admin/');


    


